package com.syq.service.impl;

import com.syq.mapper.CustomerMapper;
import com.syq.pojo.Customer;
import com.syq.service.CustomerService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @ClassName: CustomerServiceImpl
 * @Description: TODO
 * @Create by: syq
 * @Date: 2022/8/16 16:20
 */

@Service
public class CustomerServiceImpl implements CustomerService {

    @Autowired
    private CustomerMapper customerMapper;


    @Override
    public Integer add(Customer customer) {
        return customerMapper.insert(customer);
    }

    @Override
    public void update(Customer customer) {
        customerMapper.updateById(customer);
    }

    @Override
    public void del(List<Integer> ids) {
        customerMapper.deleteBatchIds(ids);
    }
}
